wayland: Keep hotspot when changing cursors
authorMatthias Clasen <mclasen@redhat.com>
Thu, 21 Mar 2013 01:47:12 +0000 (21:47 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Thu, 21 Mar 2013 02:21:15 +0000 (22:21 -0400)
commit26d3fc311b98c9baf2131609ff724d3e196c77f4
treebfc79199e65307abd7f003d89e211bfd817661e4
parent92e0132d3886912e34fe101e94043fb932c23968
wayland: Keep hotspot when changing cursors

We need to pass the delta between the old and new hotspot
when attaching the new cursor surface, to keep the hotspot
at the same position. We can't deal with this in the compositor,
since the set_cursor call already overwrites the old hotspot,
so the information is lost by the time the attach happens.
Unfortunately, we can't query the initial hotspot from
the compositor, so the first cursor change will make the
hotspot jump.
https://bugzilla.gnome.org/show_bug.cgi?id=695512
gdk/wayland/gdkdevice-wayland.c